module GameWorld
  module Actor
    class Actor
      attr_accessor :coord_x
      attr_accessor :coord_y
      attr_accessor :name
    end

    class Player < Actor
    end

    class Avatar < Player
      def move(x, y)
        self.coord_x = x
        self.coord_y = y
        puts("moving to " + x.to_s + "," + y.to_s)
      end

      def cast_skill(x, y)
        puts("casting skill on " + x.to_s + "," + y.to_s)
      end

      def use_item(item, target=self)
        puts("using item " + item.to_s + " on " + target.name)
      end
    end
  end
end